#import itertools
#排列 有序
# b = [1,2,3]
# d = itertools.permutations(b,2)
# for i in d:
#     print(i)
# print('**********************')
# #组合  无序
# b = [1,2,3]
# e = itertools.combinations(b,2)
# for i in e:
#     print(i)
# print('**********************')
#金额面值组合 combinations_with_replacement允许同一元素多次选择
from itertools import combinations_with_replacement as comb
def aaa():
    grp = []
    for i in range(1, 11):
        print(i)
        for j in comb([1,2,5,10],i):
            if sum(j) == 10:
                print(j)
                grp.append(j)
    return grp


xx = aaa()
print(xx)
print(len(xx))



